/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.fii.entity;

import java.io.Serializable;
import java.util.Date;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 *
 * @author Zeus
 */
@Entity
@Table(name = "pg_prog_acad", catalog = "prog_acad", schema = "")
@NamedQueries({
    @NamedQuery(name = "PgProgAcad.findAll", query = "SELECT p FROM PgProgAcad p"),
    @NamedQuery(name = "PgProgAcad.findByPgcodProgAcad", query = "SELECT p FROM PgProgAcad p WHERE p.pgcodProgAcad = :pgcodProgAcad"),
    @NamedQuery(name = "PgProgAcad.findByPgSemestre", query = "SELECT p FROM PgProgAcad p WHERE p.pgSemestre = :pgSemestre"),
    @NamedQuery(name = "PgProgAcad.findByPgcodFacultad", query = "SELECT p FROM PgProgAcad p WHERE p.pgcodFacultad = :pgcodFacultad"),
    @NamedQuery(name = "PgProgAcad.findByPgEstado", query = "SELECT p FROM PgProgAcad p WHERE p.pgEstado = :pgEstado"),
    @NamedQuery(name = "PgProgAcad.findByPgfechaRegistro", query = "SELECT p FROM PgProgAcad p WHERE p.pgfechaRegistro = :pgfechaRegistro")})
public class PgProgAcad implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "pg_codProgAcad", nullable = false, length = 10)
    private String pgcodProgAcad;
    @Basic(optional = false)
    @Column(name = "pg_semestre", nullable = false, length = 6)
    private String pgSemestre;
    @Basic(optional = false)
    @Column(name = "pg_codFacultad", nullable = false, length = 2)
    private String pgcodFacultad;
    @Basic(optional = false)
    @Column(name = "pg_estado", nullable = false)
    private char pgEstado;
    @Basic(optional = false)
    @Column(name = "pg_fecha_Registro", nullable = false)
    @Temporal(TemporalType.DATE)
    private Date pgfechaRegistro;

    public PgProgAcad() {
    }

    public PgProgAcad(String pgcodProgAcad) {
        this.pgcodProgAcad = pgcodProgAcad;
    }

    public PgProgAcad(String pgcodProgAcad, String pgSemestre, String pgcodFacultad, char pgEstado, Date pgfechaRegistro) {
        this.pgcodProgAcad = pgcodProgAcad;
        this.pgSemestre = pgSemestre;
        this.pgcodFacultad = pgcodFacultad;
        this.pgEstado = pgEstado;
        this.pgfechaRegistro = pgfechaRegistro;
    }

    public String getPgcodProgAcad() {
        return pgcodProgAcad;
    }

    public void setPgcodProgAcad(String pgcodProgAcad) {
        this.pgcodProgAcad = pgcodProgAcad;
    }

    public String getPgSemestre() {
        return pgSemestre;
    }

    public void setPgSemestre(String pgSemestre) {
        this.pgSemestre = pgSemestre;
    }

    public String getPgcodFacultad() {
        return pgcodFacultad;
    }

    public void setPgcodFacultad(String pgcodFacultad) {
        this.pgcodFacultad = pgcodFacultad;
    }

    public char getPgEstado() {
        return pgEstado;
    }

    public void setPgEstado(char pgEstado) {
        this.pgEstado = pgEstado;
    }

    public Date getPgfechaRegistro() {
        return pgfechaRegistro;
    }

    public void setPgfechaRegistro(Date pgfechaRegistro) {
        this.pgfechaRegistro = pgfechaRegistro;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (pgcodProgAcad != null ? pgcodProgAcad.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof PgProgAcad)) {
            return false;
        }
        PgProgAcad other = (PgProgAcad) object;
        if ((this.pgcodProgAcad == null && other.pgcodProgAcad != null) || (this.pgcodProgAcad != null && !this.pgcodProgAcad.equals(other.pgcodProgAcad))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.fii.entity.PgProgAcad[ pgcodProgAcad=" + pgcodProgAcad + " ]";
    }
    
}
